package com.sayyi.demo.test.common;

/**
 * @author xuchuang
 * date 2021/12/23 4:01 PM
 */
public class GlobalException extends RuntimeException {
    private ResultStatus status;

    public GlobalException(ResultStatus status) {
        super(status.getMsg());
        this.status = status;
    }

    public GlobalException(ResultStatus status, Throwable cause) {
        super(status.getMsg(), cause);
        this.status = status;
    }

    public ResultStatus getStatus() {
        return status;
    }
}
